package com.ruoyi.teaching.mapper;

import java.util.List;
import com.ruoyi.teaching.domain.StageInvestigateDetail;
import org.apache.ibatis.annotations.Select;

/**
 * 阶段问卷细节Mapper接口
 *
 * @author sunshine
 * @date 2024-02-15
 */
public interface StageInvestigateDetailMapper
{
    /**
     * 查询阶段问卷细节
     *
     * @param id 阶段问卷细节主键
     * @return 阶段问卷细节
     */
    public StageInvestigateDetail selectStageInvestigateDetailById(Long id);

    /**
     * 查询阶段问卷细节列表
     *
     * @param stageInvestigateDetail 阶段问卷细节
     * @return 阶段问卷细节集合
     */
    public List<StageInvestigateDetail> selectStageInvestigateDetailList(StageInvestigateDetail stageInvestigateDetail);

    /**
     * 新增阶段问卷细节
     *
     * @param stageInvestigateDetail 阶段问卷细节
     * @return 结果
     */
    public int insertStageInvestigateDetail(StageInvestigateDetail stageInvestigateDetail);

    /**
     * 修改阶段问卷细节
     *
     * @param stageInvestigateDetail 阶段问卷细节
     * @return 结果
     */
    public int updateStageInvestigateDetail(StageInvestigateDetail stageInvestigateDetail);

    /**
     * 删除阶段问卷细节
     *
     * @param id 阶段问卷细节主键
     * @return 结果
     */
    public int deleteStageInvestigateDetailById(Long id);

    /**
     * 批量删除阶段问卷细节
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteStageInvestigateDetailByIds(Long[] ids);

    @Select("select count(*) from ya_stage_investigate_detail where feedback_status = 1")
    Long selectCount();

    @Select("select id from ya_stage_investigate_detail where feedback_status != 1")
    List<Long> selectId();

    List<StageInvestigateDetail> selectStageInvestigateDetailListByFeed();
}
